home *** CD-ROM | disk | FTP | other *** search
/ Collection of Tools & Utilities / Collection of Tools and Utilities.iso / dskut / gd_v11.zip / EXAMPLE2.DEF < prev    next >
Text File  |  1992-12-16  |  3KB  |  103 lines

  1. # 'module' defines the module and its name
  2.  
  3. module "BOO EDITOR V.1.0" {
  4.    # The following descriptions will be attached with the module.
  5.    # They will be displayed when the module is started or when
  6.    # the users request.
  7.  
  8.    desc "Team member editor for BOO 1.0, by Mage Merlin"
  9.    desc " "
  10.    desc "This is an editor for changing member data in the game BOO."
  11.    desc "It will let you change data for each member of your team."
  12.    desc "You can change their names, sexes, races, and golds they own."
  13.  
  14.    # This is a 'relative' record which means it will be applied on
  15.    # several sets of data.
  16.  
  17.    relative "Member Data" {
  18.      # The following descriptions will be attached to the recrod.
  19.  
  20.      desc "This record contains the name, sex, and race of the"
  21.      desc "character, and the amount of golds the character has."
  22.  
  23.      # Now define the offset of the first record to the begin
  24.      # of the file, size of the record (and each data set), and
  25.      # the number of sets.
  26.      # Here it says the first data set using this record is at
  27.      # offset 0x100 (256), with a size of 40 bytes, and there
  28.      # are 4 continuous data sets starting from that offset.
  29.  
  30.      recloc 0x100 40 4
  31.  
  32.      # this is the defintion for a field
  33.  
  34.      field "Name" {
  35.         # following descriptions will be attached to the field
  36.  
  37.         desc "The name of the character.  16 characters long."
  38.  
  39.         # Here it defines the location and size of data in the
  40.         # game file.  It says that data located at offset 0 of
  41.         # the record (data set) as a size of 16 bytes long string
  42.  
  43.         data 0 16 ascii
  44.  
  45.         # Now it defines the display of the field in the entry
  46.         # form.  It is in page 0, The label of the field "Name"
  47.         # is at row 3, column 5.  The entry would be at row 3,
  48.         # column 12 as a 16 characters ASCII string.
  49.  
  50.          entry 0 3 5 3 12 16 asc
  51.      }
  52.  
  53.       field "Sex" {
  54.          # descriptions for the field.
  55.  
  56.          desc "Sex of the character."
  57.         desc " "
  58.          desc "M - Male.  F - Female.  N - Neutral."
  59.  
  60.         # data located at offset 18 of the record, 1 bytes long and
  61.         # interpreted as an ascii character.
  62.  
  63.         data 18 1 ascii
  64.  
  65.         # label at page 0, row 4, column 5
  66.         # entry at row 4, column 12, 1 byte ascii
  67.  
  68.         entry 0 4 5 4 12 1 asc
  69.      }
  70.      field "Race" {
  71.         # descriptions for the field.
  72.  
  73.         desc "The race of the character.  Data is BCD with 1 byte long."
  74.         desc " "
  75.         desc "10 - Human   11 - Orc   12 - Dwarf   13 - Werewolf."
  76.  
  77.         # data located at offset 19 of the record, 1 byte long,
  78.         # as a BCD number.  Note: every byte of BCD can hold 2 digits.
  79.  
  80.         data 19 1 bcd
  81.  
  82.         # label at page 0, row 5, column 5
  83.         # entry at row 5, column 12, 2 digits decimal
  84.  
  85.         entry 0 5 5 5 12 2 dec
  86.      }
  87.      field "Golds" {
  88.         # descriptions for the field.
  89.  
  90.         desc "The amount of golds the member has."
  91.  
  92.         # data located at offset 20 of the record. 2 byte integer.
  93.  
  94.         data 20 2 word
  95.  
  96.         # label at page 0, row 6, column 5
  97.         # entry at row 6, column 12, 5 digits decimal
  98.  
  99.          entry 0 6 5 6 12 5 dec
  100.       }
  101.    }
  102. }
  103.